package RegexBubble;

public class BubbleSortClass {
	 
	public static void bubblesort(double[] arr){
	    for(int i = arr.length-1 ; i >= 0 ; i--){
	        for(int j = 0 ; j < i ; j++){
	            if( arr[j] > arr[j+1] )
	               swap(arr, j, j+1);
	        }
	    }
	}
	private static void swap(double[] arr, int i, int j) {
	    double t = arr[i];
	    arr[i] = arr[j];
	    arr[j] = t;
	}
}
